package com.simple.dsrouter.holder;

public class DataSourceContextHolder {
	
	private static final ThreadLocal<String> contextHolder = new ThreadLocal<String>(){};

	public static String getCurrentDataSourceKey(){
        return contextHolder.get();
	}
	
	public static void setCurrentDataSourceKey(String dataSourceKey){
		contextHolder.set(dataSourceKey);
	}
	
	public static void clean(){
		contextHolder.remove();
	}

}